package com.houtai.dao;



import com.houtai.bean.User;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

@Repository
public interface UserDao {

    /**
     * @Purpose:    添加用户
     * @param:      user
     * @Version:    1.0
     * @Author:     li
     * @time:       2019/8/21
     * @return:     void
     */
    void insertUser(User user);


    /**
     * @Purpose:    用phone_no区查询用户
     * @param:      phone_no
     * @Version:    1.0
     * @Author:     li
     * @time:       2019/8/21
     * @return:     User
     */
    User findUserByPhoneNo(@Param("phone_no") String phone_no);



    /**
     * @Purpose:    跟据id用户查询
     * @param:      user_id
     * @Version:    1.0
     * @Author:     li
     * @time:       2019/8/26
     * @return:     User
     */
    User findUserId(@Param("user_id") int user_id);

    /**
     * @Purpose:    更新密码
     * @param:      user_id
     * @Version:    1.0
     * @Author:     li
     * @time:       2019/8/26
     * @return:     void
     */
    void updateUserPass(User user);

    /**
     * @Purpose:    修改用户头像
     * @param:      user_id
     * @Version:    1.0
     * @Author:     li
     * @time:       2019/8/26
     * @return:     void
     */
    void updateUserHead(User user);

    /**
     * @Purpose:    修改用户
     * @param:      user_id
     * @Version:    1.0
     * @Author:     li
     * @time:       2019/8/26
     * @return:     void
     */
    void updateUserNick(User user);
}